<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>welcome</title>
</head>
<script type="text/javascript">
    window.onload = function () {
        var user = sessionStorage.getItem("user");
        if(user == undefined && confirm("用户未登陆，请先登陆")){
            window.location.href = "/static/login.html";
            return;
        }
        document.getElementById("show").innerText = "welcome " + user;
    }
</script>
<body>
<h1 id="show"> welcome </h1>
</body>
</html>